using System.Threading.Channels;
using Vision.Abstractions;

namespace Vision.Host.Runtime
{
	/// <summary>
	/// IImageBus 的默认实现，内部使用无界 Channel。
	/// </summary>
	public class ImageBus : IImageBus
	{
		private readonly Channel<Message> _channel;

		public ImageBus()
		{
			_channel = Channel.CreateUnbounded<Message>();
		}

		public ChannelReader<Message> Reader => _channel.Reader;
		public ChannelWriter<Message> Writer => _channel.Writer;
	}
}


